<<<<<<< HEAD
import request from '@/utils/request'

// 获取收藏列表
export function getFavorites() {
  return request({
    url: '/favorites',
    method: 'get'
=======
import instance from '@/utils/request'

// 获取收藏列表
export function getFavorites() {
  return instance.request({
    url: '/favorites',
    method: 'GET'
>>>>>>> resume
  })
}

// 添加收藏
export function addFavorite(data) {
<<<<<<< HEAD
  return request({
    url: '/favorites',
    method: 'post',
=======
  return instance.request({
    url: '/favorites',
    method: 'POST',
>>>>>>> resume
    data
  })
}

// 取消收藏
export function removeFavorite(jobId) {
<<<<<<< HEAD
  return request({
    url: `/favorites/${jobId}`,
    method: 'delete'
=======
  return instance.request({
    url: `/favorites/${jobId}`,
    method: 'DELETE'
>>>>>>> resume
  })
}

// 检查是否已收藏
export function checkFavorite(jobId) {
<<<<<<< HEAD
  return request({
    url: '/favorites/check',
    method: 'get',
=======
  return instance.request({
    url: '/favorites/check',
    method: 'GET',
>>>>>>> resume
    params: { jobId }
  })
}